package com.zhkj.lib.http

import com.zhkj.lib.base.QueryShippingResponse
import com.zhkj.lib.base.UploadResponse
import io.reactivex.Observable
import okhttp3.MultipartBody
import retrofit2.http.*

interface BaseApiService {
    @Multipart
    @POST("api/common/upload")
    fun uploadPicture(@Part image: MultipartBody.Part): Observable<UploadResponse>

    @Multipart
    @POST("api/common/upload")
    fun uploadPicture(@Part list: MutableList<MultipartBody.Part>): Observable<UploadResponse>

    @GET("api/common/queryExpress")
    fun queryShipping(
        @Query("token") token: String,
        @Query("invoice_no") shippingNo: String,
        @Query("shipping_code") shippingCode: String
    ): Observable<QueryShippingResponse>
}